/*
*   DebugHUD.h
*   ___PROJECTNAME___
*
*   Created by ___FULLUSERNAME___ on ___DATE___.
*   Copyright ___ORGANIZATIONNAME___ ___YEAR___. All rights reserved.
*
*/

#ifndef __DebugHUD_h__
#define __DebugHUD_h__

#include "CESlider.h"

#include "cocos2d.h"


////////////////////////////////////////////////////////
//
class b2World;

namespace ___game_namespace___ {

////////////////////////////////////////////////////////
//
/** DebugHUD
 *  
*/
////////////////////////////////////////////////////////

class DebugHUD : public cocos2d::CCNode, public cocosext::CESliderDelegate 
{
typedef std::pair<cocos2d::CCObject*, cocos2d::CCNode*> GroupForCaller;
typedef std::vector<GroupForCaller> GroupForCallerList;

	b2World* _world;
	cocos2d::CCNode* _renderNode;
	GroupForCallerList _groups;

private:
	DebugHUD(b2World* world): _world(world), _renderNode(NULL) {;}

public:
    ~DebugHUD();
    
    // static constructor
    static cocos2d::CCNode* node(b2World* world, const cocos2d::CCSize& contentSize, const cocos2d::CCSize& parentSize);
    
public:
	//Cocos2d functions
	virtual bool init(const cocos2d::CCSize& contentSize, const cocos2d::CCSize& parentSize);


// CESliderDelegate interface
    virtual void onValueChange(cocosext::CESliderInterface* slider);

private:
// allbacks
	void onSwitchRenderer(CCObject* caller);
	void onGroupsBtnClick(CCObject* caller);

}; // class GameLayer

} // namespace ___game_namespace___


#endif // __DebugHUD_h__
